<%@ include file="/WEB-INF/tiles/include.jsp"%>

<script type="text/javascript">
	
	$(document).ready(function($) {
		$("#modalbox_save").click(function() {
			$.wis.util.doSave()
		});
	
		$("#facebox_close").click(function() {
			$.facebox.close()   
		});

		$("#dob").datepicker({
			inline: true
		});
		
	});

</script>

<form:form id="editForm" commandName="commandCustomer" method="post" action="${pageContext.request.contextPath}/basic/administrative/customer.save">
	<form:hidden path="pgIndex"/>
	<form:hidden path="pgRows"/>
	<form:hidden path="pgTotal"/>
	<form:hidden path="id"/>
	<form:hidden path="strAction"/>

<table class="tableInput">
	<tr>
		<th class="field"><spring:message code="label.firstname" />&nbsp;:</th>
		<td class="even"><form:input path="firstname" size="35" maxlength="35"/></td>
	</tr>
	<tr>
		<th class="field"><spring:message code="label.surname" />&nbsp;:</th>
		<td class="odd"><form:input path="surname" size="35" maxlength="35"/></td>
	</tr>
	<tr>
		<th class="field"><spring:message code="label.dob" />&nbsp;:</th>
		<td class="even"><form:input path="dob" size="10" maxlength="10"/></td>
	</tr>
	<tr>
		<th class="field"><spring:message code="label.address" />&nbsp;:</th>
		<td class="odd"><form:input path="address1" size="60" maxlength="70"/></td>
	</tr>
	<tr>
		<th class="field">&nbsp;</th>
		<td class="even"><form:input path="address2" size="60" maxlength="70"/></td>
	</tr>
	<tr>
		<th class="field"><spring:message code="label.suburb" />&nbsp;:</th>
		<td class="odd"><form:input path="suburb" size="50" maxlength="50"/></td>
	</tr>
	<tr>
		<th class="field"><spring:message code="label.postalcode" />&nbsp;:</th>
		<td class="even"><form:input path="postalCode" size="6" maxlength="6"/></td>
	</tr>
	<tr>
		<th class="field"><spring:message code="label.state" />&nbsp;:</th>
		<td class="odd"><form:input path="state" size="50" maxlength="50"/></td>
	</tr>
	<tr>
		<th class="field"><spring:message code="label.country" />&nbsp;:</th>
		<td class="even">
			<form:select  path="countryId"
				items="${commandCustomer.countryList}" 
				itemLabel="stLabel" 
				itemValue="stValue"/>
		</td>
	</tr>
	<tr>
		<th class="field"><spring:message code="label.homephone" />&nbsp;:</th>
		<td class="odd"><form:input path="homephone" size="15" maxlength="15"/></td>
	</tr>
	<tr>
		<th class="field"><spring:message code="label.workphone" />&nbsp;:</th>
		<td class="even"><form:input path="workphone" size="15" maxlength="15"/></td>
	</tr>
	<tr>
		<th class="field"><spring:message code="label.mobile" />&nbsp;:</th>
		<td class="odd"><form:input path="mobile" size="15" maxlength="15"/></td>
	</tr>
	<tr>
		<th class="field"><spring:message code="label.email1" />&nbsp;:</th>
		<td class="even"><form:input path="email1" size="60" maxlength="170"/></td>
	</tr>
	<tr>
		<th class="field"><spring:message code="label.email2" />&nbsp;:</th>
		<td class="odd"><form:input path="email2" size="60" maxlength="170"/></td>
	</tr>
	<tr>
		<th class="field"><spring:message code="label.idnumber" />&nbsp;:</th>
		<td class="even"><form:input path="idnumber" size="50" maxlength="50"/></td>
	</tr>
	<tr>
		<th class="field"><spring:message code="label.identity" />&nbsp;:</th>
		<td class="odd">
			<form:select  path="identificationId"
				items="${commandCustomer.identityList}" 
				itemLabel="stLabel" 
				itemValue="stValue"/>
		</td>
	</tr>
</table>
<table class="tableButton">
	<tr><td align="left">
		<span class="button"><a href="#modalbox_save" id="modalbox_save"><spring:message code="button.save"/></a></span>
		<span class="button"><a href="#facebox_close" id="facebox_close"><spring:message code="button.cancel"/></a></span>
	</td></tr>
</table>
</form:form>